from django.conf import settings
from django.core.files.storage import Storage


class FastDFSStorage(Storage):
    def __init__(self):
        self.fdfs_base_url=settings.FDFS_BASE_URL

    def _save(self,name,content):
        pass

    def _open(self,name,mode='rb'):
        pass

    def url(self, name):
        """
        http://172.17.0.1:8888/' +group1/M00/00/01/CtM3BVrLmc-AJdVSAAEI5Wm7zaw8639396
        """
        return self.fdfs_base_url+name